home *** CD-ROM | disk | FTP | other *** search
/ Champak 106 / Vol 106.iso / games / i_am_leg.swf / scripts / DefineButton2_280 / BUTTONCONDACTION on(release).as
Encoding:
Text File  |  2010-04-12  |  1.1 KB  |  44 lines

  1. on(release){
  2.    _root.remove_bg();
  3.    _root.player.swapDepths(_root.player.depth);
  4.    _root.score_menu.swapDepths(_root.score_menu.depth);
  5.    var a = _root.enemyactive - 100;
  6.    while(a < _root.enemyactive + 100)
  7.    {
  8.       _root["enemy" + a].removeMovieClip();
  9.       _root["boss_mc" + a].removeMovieClip();
  10.       a++;
  11.    }
  12.    var a = _root.ammoactive - 100;
  13.    while(a < _root.ammoactive + 100)
  14.    {
  15.       _root["ammo" + a].removeMovieClip();
  16.       a++;
  17.    }
  18.    var a = _root.ammoactive - 100;
  19.    while(a < _root.ammoactive + 100)
  20.    {
  21.       _root["weili_mc" + a].removeMovieClip();
  22.       a++;
  23.    }
  24.    var a = _root.lifeactive - 100;
  25.    while(a < _root.lifeactive + 100)
  26.    {
  27.       _root["add_life" + a].removeMovieClip();
  28.       a++;
  29.    }
  30.    var a = _root.ammoactive - 100;
  31.    while(a < _root.ammoactive + 1)
  32.    {
  33.       _root["hanbao_mc" + a].removeMovieClip();
  34.       a++;
  35.    }
  36.    var a = _root.ammoactive - 100;
  37.    while(a < _root.ammoactive + 1)
  38.    {
  39.       _root["shengdai_mc" + a].removeMovieClip();
  40.       a++;
  41.    }
  42.    _parent._parent.gotoAndStop("start");
  43. }
  44.